{
  "cells": [
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "xp9lQNIvUg4d"
      },
      "source": [
        "# Working with the Loong environment"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "7V3aV16AmY0K"
      },
      "source": [
        "You can also check out this cookbook in Google Colab [here](https://colab.research.google.com/drive/1mMJ4tiAasixj_N422LW80ktFLIvSuYlB?usp=sharing)."
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "UvHRdXwflAz-"
      },
      "source": [
        "<div class=\"align-center\">\n",
        "  <a href=\"https://www.camel-ai.org/\"><img src=\"https://i.postimg.cc/KzQ5rfBC/button.png\"width=\"150\"></a>\n",
        "  <a href=\"https://discord.camel-ai.org\"><img src=\"https://i.postimg.cc/L4wPdG9N/join-2.png\"  width=\"150\"></a></a>\n",
        "  \n",
        "⭐ <i>Star us on [*Github*](https://github.com/camel-ai/camel), join our [*Discord*](https://discord.camel-ai.org) or follow our [*X*](https://x.com/camelaiorg)\n",
        "</div>"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "XZx1YuxtUIaT"
      },
      "outputs": [],
      "source": [
        "# Optional: Install camel if you don't have it\n",
        "!pip install \"git+https://github.com/camel-ai/camel.git@ce5ee0a3ceda7eb8dd4f42047ee2fe538abfd561#egg=camel-ai[all]\""
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "XtQdrgZNUg4e"
      },
      "source": [
        "The Loong *environment* is a unified interface that can be used for Synthetic Data Generation, RL training and Benchmarking agents. It integrates all the primitives that we implemented at CAMEL to provide a nice interface for developers and researchers. In this cookbook, we will explain how to initialize a *Single Step Environment* to generate synthetic data. More cookbooks about RL training and how to customize the environment are coming soon.\n",
        "\n",
        "This type of environment is called a *single step* environment, because the agent only does one step. It gets a question sampled from the dataset (the initial state / observation) and then answers. The answer is then scored according to the reward function. Recently, rules-based reward functions, i.e. functions without any learnable parameters, have been successfully used to do RL with LLMs as as policy.\n",
        "\n",
        "Since many RL algorithms (such as GRPO) need multiple rollouts at each step, batching is important to guarantee concurrency / parallelism. Our `SingleStepEnv` supports batching (both `reset` and `step`), but for the sake of simplicity, we will not use batching for this cookbook. We will soon release another cookbook dedicated to batching.\n",
        "\n",
        "First, we have to load a dataset from which we will sample questions. The dataset can be either a `StaticDataset`, which is finite, or it can be a `BaseGenerator`, which is an infinite supply of question - answer pairs, synthetically generated in some way, depending on the implementation. To seed the generative process of the `BaseGenerator`, we need to seed it with a *seed dataset*. Each generator uses the seed dataset it was initialized with to generate new data.\n",
        "\n",
        "In this cookbook, we will use the `FewShotGenerator`, which will generate new data points by doing simple few-shot prompting, using random data points from the seed dataset as examples.\n",
        "\n",
        "A seed dataset can easily be thought of as a type of `StaticDataset`, so let's initialize our seed dataset as such a `StaticDataset`."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 177,
          "referenced_widgets": [
            "cd861fabffc24ce697ac187f35ec2bc5",
            "d4c287f4624b4d15a7758cf8c6793b34",
            "7060db90f16d49b6986bfd1a040c9929",
            "273277b242ce46daaf14dbda175f80d8",
            "4d816b309a884bc384fd8a0fb3f4cfd2",
            "5711a7aec0394db4ade925a4d0cdaa83",
            "569fc3c33bf04d47ac0597dff601b645",
            "03af9d13e3f246f6a6b8daf80b55d82e",
            "92de59cd575045f285292b4310bac783",
            "07467616d7a840f8988fcdc6c55c7928",
            "00dbf52aea894270bcce0ac28a4db60d",
            "d33208a4ad0c4e22a67f52737b5d50c5",
            "ad1c59a690644609b13dfddca37cad74",
            "627dcd02c8f540e89b3340a4e13c2bbc",
            "81b1f75700ba4b41a711d9852d04236e",
            "a0c35e93994e4d2a8e6e41ecaa736d71",
            "244da506ff744429b2cd2cb6fa5dcc35",
            "7eaf1ace438947c58540441dd1909d10",
            "e6fcba902fb847c98188052718187165",
            "23c89b34fe054fb4a642ace5644aa9aa",
            "354471cc7a724ecb8e413e0a21fafe66",
            "913fabc02871423497e1cc444e78821d",
            "f50db0d59a154521b7f58a41df0cc06b",
            "c9ebed435b62445d8cbe15df5121f897",
            "cb43fb794aba4a97b0ef692714882041",
            "110c3359857d4e55b50a76868bff2821",
            "9766872adbf345368d48f2402de8982e",
            "e607886d3cbd4257af1371123b17ee4a",
            "51d7d870d8f2434894b71643f172e6f7",
            "36a3fe0b544c47539719498d72444a90",
            "309c81c8a6dd4cba9c951300fb4bb5e2",
            "2156ddab7c4b47059a94c2829660aa6a",
            "0885bdf2f6884947a6e8bdae3a71670f",
            "09c5d1d9fda64a82925c51fbcec5b5b0",
            "eb0f971f88c14ded97c9b7cc47d3beec",
            "6ae22cde2de04a76a846c8b738e585ce",
            "84385e4cee64432ba13e781e9893557e",
            "d7aede4d86964fff8cdf8a8e228bf816",
            "fc969f0e54f845228da86794e0ab3af1",
            "36deafc454c743718fe1302db3f54459",
            "73b6095921514988b2680d6f98694f84",
            "3791b9a4286a4aceaff153cab8a7149a",
            "f73873e351a04a47abd3f067ffefa812",
            "69ab2fdbe42f4b828eebe7d7e96f51c2",
            "1536a223a2524ca594195e913669cf08",
            "2d65d5df3b5940a19a37fa5a6e79b171",
            "a4a4603184c84ea9bfb7afb686ec6d04",
            "91189dbb66744be88a6800e83a72c1d0",
            "9a2c3f47a31945d4ae4a15b1e6ff3dd9",
            "2387bec179144eeca0eb18dd13951ef0",
            "f52950002e984c21abe60ea75cbc0a81",
            "7a8ac4fe8f7e4e8980c7b59b831ba0a2",
            "15821bf8ec5042f38012e65a6a219725",
            "3de3d65c81ae4cb890edd8ca2a775335",
            "8ad927c14cb545949b9a0469f56a2247"
          ]
        },
        "id": "sZdba1LJUg4e",
        "outputId": "eaff3044-3d89-49f7-830e-efd4c6fb7b8d"
      },
      "outputs": [
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "graph_discrete_math/test-00000-of-00001.(…):   0%|          | 0.00/26.7k [00:00<?, ?B/s]"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "cd861fabffc24ce697ac187f35ec2bc5"
            }
          },
          "metadata": {}
        },
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "graph_discrete_math/train-00000-of-00001(…):   0%|          | 0.00/17.1k [00:00<?, ?B/s]"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "d33208a4ad0c4e22a67f52737b5d50c5"
            }
          },
          "metadata": {}
        },
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "Generating test split:   0%|          | 0/125 [00:00<?, ? examples/s]"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "f50db0d59a154521b7f58a41df0cc06b"
            }
          },
          "metadata": {}
        },
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "Generating train split:   0%|          | 0/53 [00:00<?, ? examples/s]"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "09c5d1d9fda64a82925c51fbcec5b5b0"
            }
          },
          "metadata": {}
        },
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "Map:   0%|          | 0/53 [00:00<?, ? examples/s]"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "1536a223a2524ca594195e913669cf08"
            }
          },
          "metadata": {}
        }
      ],
      "source": [
        "from camel.datasets import StaticDataset\n",
        "from datasets import load_dataset\n",
        "import json\n",
        "\n",
        "# Load the dataset and select a specific split\n",
        "dataset = load_dataset(\"camel-ai/loong\", \"graph_discrete_math\", split=\"train\")\n",
        "\n",
        "# Convert metadata from string to dict\n",
        "def process_sample(sample):\n",
        "    if isinstance(sample['metadata'], str):\n",
        "        sample['metadata'] = json.loads(sample['metadata'])\n",
        "    return sample\n",
        "\n",
        "# Apply the processing to all samples\n",
        "dataset = dataset.map(process_sample)\n",
        "\n",
        "seed_dataset = StaticDataset(dataset)"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "WIOX8ztVUIaT"
      },
      "source": [
        "Let's take a look at an example data point"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "-l7UHBUKY-rJ",
        "outputId": "871226f9-5ed3-4997-c5a8-871c1be8f25e"
      },
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Question: In a cycle graph with 4 vertices, do the nodes [2, 3, 0] form a simple path? Return True if they form a simple path, otherwise return False.\n",
            "Final Answer: True\n"
          ]
        }
      ],
      "source": [
        "example = seed_dataset[0]\n",
        "\n",
        "print(f\"Question: {example.question}\")\n",
        "print(f\"Final Answer: {example.final_answer}\")"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "5h-s-T6yUg4f"
      },
      "source": [
        "The `FewShotGenerator` needs a python interpreter to compute a synthetic answer (pseudo ground truth) from the code it generated. For this, let's define a `PythonVerifier`.\n",
        "\n",
        "Note: We will soon use dedicated CAMEL-based code interpreters instead of repurposing our Python verifier for this."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "wrkXNgTHUg4f"
      },
      "outputs": [],
      "source": [
        "from camel.verifiers import PythonVerifier\n",
        "from camel.agents import ChatAgent\n",
        "from camel.extractors import BaseExtractor, BoxedStrategy\n",
        "\n",
        "interpreter = PythonVerifier(required_packages=[\"numpy\", \"networkx\"])\n",
        "await interpreter.setup(uv=True)"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "j0LJzJHxUg4f"
      },
      "source": [
        "Lastly, we need a model backend for the generation agent. Let's use the `ModelFactory` to create one.\n",
        "\n",
        "Note: We use GPT-4o mini as a default here, hence we load our OpenAI API key. Feel free to use other models!"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "iz_GyOdTUg4f",
        "outputId": "05175253-ff04-417e-8637-d90e79d25d95"
      },
      "outputs": [
        {
          "name": "stdout",
          "output_type": "stream",
          "text": [
            "Enter your API key: ··········\n"
          ]
        }
      ],
      "source": [
        "import os\n",
        "from getpass import getpass\n",
        "\n",
        "openai_api_key = getpass('Enter your API key: ')\n",
        "os.environ[\"OPENAI_API_KEY\"] = openai_api_key"
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "zYpsSJ1HUg4g"
      },
      "outputs": [],
      "source": [
        "from camel.models import ModelFactory\n",
        "from camel.types import ModelPlatformType, ModelType\n",
        "from camel.configs import ChatGPTConfig\n",
        "from camel.datasets import FewShotGenerator\n",
        "\n",
        "model = ModelFactory.create(\n",
        "    model_platform=ModelPlatformType.OPENAI,\n",
        "    model_type=ModelType.GPT_4O_MINI,\n",
        "    model_config_dict=ChatGPTConfig().as_dict(),\n",
        ")\n",
        "\n",
        "# Note: When the generator is exhausted, it will create 20 new datapoints by default\n",
        "# To save money on the API, let's set this number to 2 instead, so we don't generate more than we need.\n",
        "generator = FewShotGenerator(\n",
        "    buffer=2, seed_dataset=seed_dataset, verifier=interpreter, model=model\n",
        ")"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "CrNvc945efey"
      },
      "source": [
        "Let's next create a verifier that extracts content inside a `\\boxed{...}` from the llm response and compares it semantically to the reference answer.\n",
        "\n",
        "Since we want Loong to be flexible, we utilize built a dedicated extraction module that defines how to parse the llm response and extract the relevant portion that we want to compare. A dedicated cookbook on how to use it is coming soon."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "tgjrKwl0eekB"
      },
      "outputs": [],
      "source": [
        "from camel.verifiers import PythonVerifier\n",
        "from camel.agents import ChatAgent\n",
        "from camel.extractors import BaseExtractor, BoxedStrategy\n",
        "\n",
        "# Initialize extractor\n",
        "extractor = BaseExtractor([[BoxedStrategy()]])\n",
        "await extractor.setup()\n",
        "\n",
        "\n",
        "verifier = PythonVerifier(extractor=extractor, required_packages=[\"numpy\", \"networkx\"])\n",
        "await verifier.setup(uv=True)"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "fQFa-ZJoUg4g"
      },
      "source": [
        "Now that our generator and verifier are all set up, let's create a `SingleStepEnv` with it.\n",
        "\n",
        "We can then call `env.reset()` to sample the underlying generator, which returns that question as an observation. We can then feed this observation into the CoT agent."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "TL81svP-Ug4g",
        "outputId": "aa2b7db7-fe51-4550-c88e-7026e4c8ebd2"
      },
      "outputs": [
        {
          "output_type": "stream",
          "name": "stderr",
          "text": [
            "WARNING:camel.camel.datasets.few_shot_generator:Verifier issue: Verifier unsuccessful, response: status=<VerificationOutcome.ERROR: 'error'> result='' duration=1.4215400218963623 timestamp=datetime.datetime(2025, 9, 1, 20, 8, 43, 2953) metadata={'attempt': 1} error_message='Solution code error:\\nTraceback (most recent call last):\\n  File \"/tmp/tmpkzexe60w.py\", line 4, in <module>\\n    print(nx.pagerank(G))\\n          ^^^^^^^^^^^^^^\\n  File \"/tmp/tmppis8zfd_/lib/python3.12/site-packages/networkx/utils/decorators.py\", line 784, in func\\n    return argmap._lazy_compile(__wrapper)(*args, **kwargs)\\n           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\\n  File \"<class \\'networkx.utils.decorators.argmap\\'> compilation 16\", line 3, in argmap_pagerank_13\\n  File \"/tmp/tmppis8zfd_/lib/python3.12/site-packages/networkx/utils/backends.py\", line 535, in _call_if_no_backends_installed\\n    return self.orig_func(*args, **kwargs)\\n           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\\n  File \"/tmp/tmppis8zfd_/lib/python3.12/site-packages/networkx/algorithms/link_analysis/pagerank_alg.py\", line 110, in pagerank\\n    return _pagerank_scipy(\\n           ^^^^^^^^^^^^^^^^\\n  File \"/tmp/tmppis8zfd_/lib/python3.12/site-packages/networkx/algorithms/link_analysis/pagerank_alg.py\", line 453, in _pagerank_scipy\\n    import scipy as sp\\nModuleNotFoundError: No module named \\'scipy\\'', retrying... (1/10)\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Observation: question='In a weighted directed graph with edges defined as follows: (0, 1, 5), (0, 2, 10), (1, 2, 2), (1, 3, 1), and (2, 3, 3), what is the shortest path from node 0 to node 3 and its total weight? Return the path as a list and the total weight as a tuple (path, total_weight).' context={} metadata={}\n"
          ]
        }
      ],
      "source": [
        "from camel.environments import SingleStepEnv\n",
        "\n",
        "env = SingleStepEnv(generator, verifier)\n",
        "await env.setup()\n",
        "\n",
        "obs = await env.reset(seed=42)\n",
        "\n",
        "print(f\"Observation: {obs}\")"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "9jTmV405Ug4g"
      },
      "source": [
        "The agent would then process this observation and select an action, which it would feed into the `step` function, which feeds it back into the environment. More specifically, it feeds it back into the verifier, which then returns a reward based on whether the llm response and reference answer are aligned or not.\n",
        "\n",
        "Let's first define a CAMEL agent and feed it the observation. Afterwards, we use the `step` function of the environment to get a reward."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "hGC17YF8Ug4g",
        "outputId": "42b789ed-ad82-4774-e7fa-6ee2f393c99f"
      },
      "outputs": [
        {
          "output_type": "stream",
          "name": "stderr",
          "text": [
            "WARNING:camel.camel.environments.single_step:Auto-converting from str to Action\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Is the episode done?: True\n",
            "Next Observation: question='Episode ended. This is just a placeholder.' context={} metadata=None\n",
            "Reward: 1.0\n",
            "Info: {'proposed_solution': \"To find the shortest path in a weighted directed graph, we can use Dijkstra's Algorithm. This algorithm is well-suited for graphs with non-negative weights. Let's go through the process step-by-step.\\n\\n### Step 1: Represent the Graph\\n\\nFirst, we represent the graph based on the provided edges:\\n\\n- Edges: (0, 1, 5), (0, 2, 10), (1, 2, 2), (1, 3, 1), (2, 3, 3)\\n  \\nFrom this, we can construct an adjacency list to easily access neighboring nodes and their weights:\\n\\n```\\ngraph = {\\n    0: [(1, 5), (2, 10)],\\n    1: [(2, 2), (3, 1)],\\n    2: [(3, 3)],\\n    3: []\\n}\\n```\\n\\n### Step 2: Initialize Dijkstra's Algorithm\\n\\nNext, we initialize:\\n- `distances`: A dictionary to keep track of the shortest distance from the source node (node 0) to each node, starting with infinity for all nodes except the start node which is 0.\\n- `previous_nodes`: A dictionary to help reconstruct the path later.\\n- A priority queue (or a simple list in our case) to explore the node with the shortest distance.\\n\\nThe initial setup is:\\n```python\\nimport heapq\\n\\ndistances = {0: 0, 1: float('inf'), 2: float('inf'), 3: float('inf')}\\nprevious_nodes = {0: None}\\npriority_queue = [(0, 0)]  # (distance, node)\\n```\\n\\n### Step 3: Find the Shortest Path\\n\\nWe now process the priority queue:\\n\\n1. Pop the node with the smallest distance from the queue.\\n2. For each neighboring node, calculate the distance and update if this new distance is shorter.\\n\\n**Iteration 1: Process Node 0**\\n- Current node: 0, Current distance: 0\\n- Neighbors: (1, weight 5) and (2, weight 10)\\n\\nUpdate distances:\\n- For node 1: New distance = 0 + 5 = 5 (update)\\n- For node 2: New distance = 0 + 10 = 10 (update)\\n\\n```python\\ndistances = {0: 0, 1: 5, 2: 10, 3: float('inf')}\\nprevious_nodes = {0: None, 1: 0, 2: 0}\\npriority_queue = [(5, 1), (10, 2)]\\n```\\n\\n**Iteration 2: Process Node 1**\\n- Current node: 1, Current distance: 5\\n- Neighbors: (2, weight 2) and (3, weight 1)\\n\\nUpdate distances:\\n- For node 2: New distance = 5 + 2 = 7 (update)\\n- For node 3: New distance = 5 + 1 = 6 (update)\\n\\n```python\\ndistances = {0: 0, 1: 5, 2: 7, 3: 6}\\nprevious_nodes = {0: None, 1: 0, 2: 1, 3: 1}\\npriority_queue = [(6, 3), (7, 2)]\\n```\\n\\n**Iteration 3: Process Node 3**\\n- Current node: 3, Current distance: 6\\n- No neighbors to process.\\n\\n**Iteration 4: Process Node 2**\\n- Current node: 2, Current distance: 7\\n- Neighbor: (3, weight 3)\\n\\nUpdate distances:\\n- For node 3: New distance = 7 + 3 = 10 (not an update since 6 is lower)\\n\\n### Step 4: Reconstruct the Shortest Path\\n\\nAt this point, we can find the shortest path from node 0 to node 3 by backtracking using the `previous_nodes` dictionary:\\n\\n- Start from node 3, go back to node 1, and then to node 0.\\n\\nPath: 0 → 1 → 3\\n\\n### Final Result\\n\\nThe total weight of the path from node 0 to node 3 is 6. We can represent the path and weight in the desired format.\\n\\nThe final output is:\\n- Path as a list: [0, 1, 3]\\n- Total weight as a tuple: (0, 1, 3), 6\\n\\nThus, the answer is:\\n\\n\\\\[\\n\\\\text{Final Answer: } \\\\text{(path, total_weight) } = ([0, 1, 3], 6)\\n\\\\]\\n\\nRepresented in Python:\\n\\n```python\\n([0, 1, 3], 6)\\n``` \\n\\nSo, the final answer formatted is:\\n\\n\\\\[\\n\\\\boxed{([0, 1, 3], 6)}\\n\\\\]\", 'verification_result': VerificationResult(status=<VerificationOutcome.SUCCESS: 'success'>, result='([0, 1, 3], 6)', duration=0.0002665519714355469, timestamp=datetime.datetime(2025, 9, 1, 20, 9, 19, 991539), metadata={'attempt': 1}, error_message=None), 'state': DataPoint(question='In a weighted directed graph with edges defined as follows: (0, 1, 5), (0, 2, 10), (1, 2, 2), (1, 3, 1), and (2, 3, 3), what is the shortest path from node 0 to node 3 and its total weight? Return the path as a list and the total weight as a tuple (path, total_weight).', final_answer='([0, 1, 3], 6)', rationale=\"import networkx as nx\\n\\nG = nx.DiGraph()\\nG.add_weighted_edges_from([(0, 1, 5), (0, 2, 10), (1, 2, 2), (1, 3, 1), (2, 3, 3)])\\nshortest_path = nx.shortest_path(G, source=0, target=3, weight='weight')\\ntotal_weight = nx.shortest_path_length(G, source=0, target=3, weight='weight')\\nprint((shortest_path, total_weight))\\n\", metadata={'synthetic': 'True', 'created': '2025-09-01T20:08:47.406121', 'generator': 'few_shot'}), 'rewards_dict': {'correctness': 1.0}}\n"
          ]
        }
      ],
      "source": [
        "agent = ChatAgent(model=model)\n",
        "\n",
        "USER_PROMPT = r\"\"\"\n",
        "You are an agent designed to answer mathematical questions with clarity and precision. Your task is to provide a step-by-step explanation for\n",
        "any mathematical problem posed by the user, ensuring the response is easy to follow. Adhere to these guidelines:\n",
        "Analyze the mathematical question carefully and break down the solution process into clear, logical steps.\n",
        "Use natural language to explain each step, incorporating LaTeX notation (e.g., $x + 2$)\n",
        "for mathematical expressions when helpful. Conclude your response with the final answer enclosed\n",
        "in a LaTeX \\boxed{} environment (e.g., \\boxed{5}).\n",
        "Place this at the end of your explanation as a standalone statement.\n",
        "It should be a Python expression, for example \"[1, 2, 3]\" for a list.\n",
        "\n",
        "The question you should answer is: \"\"\"\n",
        "\n",
        "response = agent.step(USER_PROMPT + obs.question).msgs[0].content\n",
        "\n",
        "next_obs, reward, done, info = await env.step(response)\n",
        "\n",
        "agent.reset()\n",
        "\n",
        "print(f\"Is the episode done?: {done}\")\n",
        "print(f\"Next Observation: {next_obs}\")\n",
        "print(f\"Reward: {reward}\")\n",
        "print(f\"Info: {info}\")"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "1HoYlql1UIaW"
      },
      "source": [
        "As you can see, the `step` function does exactly what you would expect it to do, if you know how Gym works.\n",
        "\n",
        "`done` is always `True` in this case, since we are in a *single step* environment. This is also the reason that `next_obs` is a placeholder observation, as there is no next observation for this episode.\n",
        "\n",
        "`reward` is the **total** reward for this action. By default, we only use an *accuracy reward*, i.e. $0$ if verifier returns that llm response and synthetic answer are not the same and $10$ otherwise. The accuracy reward can be manually set to any number by simply overriding the attribute of the environment (e.g. `env.ACCURACY_REWARD = 1`). We will add a cookbook soon that shows how to create a custom reward by extending `SingleStepEnv`.\n",
        "\n",
        "Finally, `info` is a dict containing a lot of information about the specifc interaction with the environment. For example, it contains a dict listing the different components of the total reward."
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "01crFDLvbNCz"
      },
      "source": [
        "### Environment Loop\n",
        "\n",
        "Let's look at how this would look like in a typical loop."
      ]
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "Tv2EM-HqbPRn",
        "outputId": "fbd36354-d720-4c2d-dca8-4034e399a371"
      },
      "outputs": [
        {
          "output_type": "stream",
          "name": "stderr",
          "text": [
            "WARNING:camel.camel.environments.single_step:Auto-converting from str to Action\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Reward at step 0: 0.0\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stderr",
          "text": [
            "WARNING:camel.camel.environments.single_step:Auto-converting from str to Action\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Reward at step 1: 1.0\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stderr",
          "text": [
            "WARNING:camel.camel.environments.single_step:Auto-converting from str to Action\n"
          ]
        },
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Reward at step 2: 0.0\n"
          ]
        }
      ],
      "source": [
        "for i in range(3):\n",
        "  obs = await env.reset()\n",
        "  response = agent.step(USER_PROMPT + obs.question).msgs[0].content\n",
        "\n",
        "  next_obs, reward, done, info = await env.step(response)\n",
        "  print(f\"Reward at step {i}: {reward}\")\n",
        "  agent.reset() # to clear context window"
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "WOsSOn3jUIaW"
      },
      "source": [
        "In practice, the agent's model backend would point at an inference engine like vllm or SGLang. After each `step` call (or batches thereof), we would feed the reward for the action into a training framework like *veRL* or *HuggingFace TRL*. These would update the model backend that the agent points to, such that after every training step, the new iteration of the model is used for choosing an action."
      ]
    },
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "OZdVJlblUIaW"
      },
      "source": [
        "Naturally, this setup may seem overkill. In the near future, we will explore multi-step environments like Chess, Go and GAIA, which is why we created this framework to unify RL training. We will work in the coming weeks to make it more efficient and release educational material on how to use it.\n",
        "\n",
        "We are looking forward to see what you build using the Loong environment! Feel free to share it with us on 𝕏."
      ]
    }
  ],
  "metadata": {
    "colab": {
      "provenance": []
    },
    "kernelspec": {
      "display_name": ".venv",
      "language": "python",
      "name": "python3"
    },
    "language_info": {
      "codemirror_mode": {
        "name": "ipython",
        "version": 3
      },
      "file_extension": ".py",
      "mimetype": "text/x-python",
      "name": "python",
      "nbconvert_exporter": "python",
      "pygments_lexer": "ipython3",
      "version": "3.11.11"
    },
    "widgets": {
      "application/vnd.jupyter.widget-state+json": {
        "cd861fabffc24ce697ac187f35ec2bc5": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_d4c287f4624b4d15a7758cf8c6793b34",
              "IPY_MODEL_7060db90f16d49b6986bfd1a040c9929",
              "IPY_MODEL_273277b242ce46daaf14dbda175f80d8"
            ],
            "layout": "IPY_MODEL_4d816b309a884bc384fd8a0fb3f4cfd2"
          }
        },
        "d4c287f4624b4d15a7758cf8c6793b34": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_5711a7aec0394db4ade925a4d0cdaa83",
            "placeholder": "​",
            "style": "IPY_MODEL_569fc3c33bf04d47ac0597dff601b645",
            "value": "graph_discrete_math/test-00000-of-00001.(…): 100%"
          }
        },
        "7060db90f16d49b6986bfd1a040c9929": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "FloatProgressModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "FloatProgressModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ProgressView",
            "bar_style": "success",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_03af9d13e3f246f6a6b8daf80b55d82e",
            "max": 26736,
            "min": 0,
            "orientation": "horizontal",
            "style": "IPY_MODEL_92de59cd575045f285292b4310bac783",
            "value": 26736
          }
        },
        "273277b242ce46daaf14dbda175f80d8": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_07467616d7a840f8988fcdc6c55c7928",
            "placeholder": "​",
            "style": "IPY_MODEL_00dbf52aea894270bcce0ac28a4db60d",
            "value": " 26.7k/26.7k [00:00&lt;00:00, 35.0kB/s]"
          }
        },
        "4d816b309a884bc384fd8a0fb3f4cfd2": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "5711a7aec0394db4ade925a4d0cdaa83": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "569fc3c33bf04d47ac0597dff601b645": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "03af9d13e3f246f6a6b8daf80b55d82e": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "92de59cd575045f285292b4310bac783": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ProgressStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ProgressStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "bar_color": null,
            "description_width": ""
          }
        },
        "07467616d7a840f8988fcdc6c55c7928": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "00dbf52aea894270bcce0ac28a4db60d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "d33208a4ad0c4e22a67f52737b5d50c5": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_ad1c59a690644609b13dfddca37cad74",
              "IPY_MODEL_627dcd02c8f540e89b3340a4e13c2bbc",
              "IPY_MODEL_81b1f75700ba4b41a711d9852d04236e"
            ],
            "layout": "IPY_MODEL_a0c35e93994e4d2a8e6e41ecaa736d71"
          }
        },
        "ad1c59a690644609b13dfddca37cad74": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_244da506ff744429b2cd2cb6fa5dcc35",
            "placeholder": "​",
            "style": "IPY_MODEL_7eaf1ace438947c58540441dd1909d10",
            "value": "graph_discrete_math/train-00000-of-00001(…): 100%"
          }
        },
        "627dcd02c8f540e89b3340a4e13c2bbc": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "FloatProgressModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "FloatProgressModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ProgressView",
            "bar_style": "success",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_e6fcba902fb847c98188052718187165",
            "max": 17132,
            "min": 0,
            "orientation": "horizontal",
            "style": "IPY_MODEL_23c89b34fe054fb4a642ace5644aa9aa",
            "value": 17132
          }
        },
        "81b1f75700ba4b41a711d9852d04236e": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_354471cc7a724ecb8e413e0a21fafe66",
            "placeholder": "​",
            "style": "IPY_MODEL_913fabc02871423497e1cc444e78821d",
            "value": " 17.1k/17.1k [00:00&lt;00:00, 76.7kB/s]"
          }
        },
        "a0c35e93994e4d2a8e6e41ecaa736d71": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "244da506ff744429b2cd2cb6fa5dcc35": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "7eaf1ace438947c58540441dd1909d10": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "e6fcba902fb847c98188052718187165": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "23c89b34fe054fb4a642ace5644aa9aa": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ProgressStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ProgressStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "bar_color": null,
            "description_width": ""
          }
        },
        "354471cc7a724ecb8e413e0a21fafe66": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "913fabc02871423497e1cc444e78821d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "f50db0d59a154521b7f58a41df0cc06b": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_c9ebed435b62445d8cbe15df5121f897",
              "IPY_MODEL_cb43fb794aba4a97b0ef692714882041",
              "IPY_MODEL_110c3359857d4e55b50a76868bff2821"
            ],
            "layout": "IPY_MODEL_9766872adbf345368d48f2402de8982e"
          }
        },
        "c9ebed435b62445d8cbe15df5121f897": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_e607886d3cbd4257af1371123b17ee4a",
            "placeholder": "​",
            "style": "IPY_MODEL_51d7d870d8f2434894b71643f172e6f7",
            "value": "Generating test split: 100%"
          }
        },
        "cb43fb794aba4a97b0ef692714882041": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "FloatProgressModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "FloatProgressModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ProgressView",
            "bar_style": "success",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_36a3fe0b544c47539719498d72444a90",
            "max": 125,
            "min": 0,
            "orientation": "horizontal",
            "style": "IPY_MODEL_309c81c8a6dd4cba9c951300fb4bb5e2",
            "value": 125
          }
        },
        "110c3359857d4e55b50a76868bff2821": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_2156ddab7c4b47059a94c2829660aa6a",
            "placeholder": "​",
            "style": "IPY_MODEL_0885bdf2f6884947a6e8bdae3a71670f",
            "value": " 125/125 [00:00&lt;00:00, 1728.69 examples/s]"
          }
        },
        "9766872adbf345368d48f2402de8982e": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "e607886d3cbd4257af1371123b17ee4a": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "51d7d870d8f2434894b71643f172e6f7": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "36a3fe0b544c47539719498d72444a90": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "309c81c8a6dd4cba9c951300fb4bb5e2": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ProgressStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ProgressStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "bar_color": null,
            "description_width": ""
          }
        },
        "2156ddab7c4b47059a94c2829660aa6a": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "0885bdf2f6884947a6e8bdae3a71670f": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "09c5d1d9fda64a82925c51fbcec5b5b0": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_eb0f971f88c14ded97c9b7cc47d3beec",
              "IPY_MODEL_6ae22cde2de04a76a846c8b738e585ce",
              "IPY_MODEL_84385e4cee64432ba13e781e9893557e"
            ],
            "layout": "IPY_MODEL_d7aede4d86964fff8cdf8a8e228bf816"
          }
        },
        "eb0f971f88c14ded97c9b7cc47d3beec": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_fc969f0e54f845228da86794e0ab3af1",
            "placeholder": "​",
            "style": "IPY_MODEL_36deafc454c743718fe1302db3f54459",
            "value": "Generating train split: 100%"
          }
        },
        "6ae22cde2de04a76a846c8b738e585ce": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "FloatProgressModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "FloatProgressModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ProgressView",
            "bar_style": "success",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_73b6095921514988b2680d6f98694f84",
            "max": 53,
            "min": 0,
            "orientation": "horizontal",
            "style": "IPY_MODEL_3791b9a4286a4aceaff153cab8a7149a",
            "value": 53
          }
        },
        "84385e4cee64432ba13e781e9893557e": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_f73873e351a04a47abd3f067ffefa812",
            "placeholder": "​",
            "style": "IPY_MODEL_69ab2fdbe42f4b828eebe7d7e96f51c2",
            "value": " 53/53 [00:00&lt;00:00, 1988.52 examples/s]"
          }
        },
        "d7aede4d86964fff8cdf8a8e228bf816": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "fc969f0e54f845228da86794e0ab3af1": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "36deafc454c743718fe1302db3f54459": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "73b6095921514988b2680d6f98694f84": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "3791b9a4286a4aceaff153cab8a7149a": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ProgressStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ProgressStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "bar_color": null,
            "description_width": ""
          }
        },
        "f73873e351a04a47abd3f067ffefa812": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "69ab2fdbe42f4b828eebe7d7e96f51c2": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "1536a223a2524ca594195e913669cf08": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_2d65d5df3b5940a19a37fa5a6e79b171",
              "IPY_MODEL_a4a4603184c84ea9bfb7afb686ec6d04",
              "IPY_MODEL_91189dbb66744be88a6800e83a72c1d0"
            ],
            "layout": "IPY_MODEL_9a2c3f47a31945d4ae4a15b1e6ff3dd9"
          }
        },
        "2d65d5df3b5940a19a37fa5a6e79b171": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_2387bec179144eeca0eb18dd13951ef0",
            "placeholder": "​",
            "style": "IPY_MODEL_f52950002e984c21abe60ea75cbc0a81",
            "value": "Map: 100%"
          }
        },
        "a4a4603184c84ea9bfb7afb686ec6d04": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "FloatProgressModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "FloatProgressModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ProgressView",
            "bar_style": "success",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_7a8ac4fe8f7e4e8980c7b59b831ba0a2",
            "max": 53,
            "min": 0,
            "orientation": "horizontal",
            "style": "IPY_MODEL_15821bf8ec5042f38012e65a6a219725",
            "value": 53
          }
        },
        "91189dbb66744be88a6800e83a72c1d0": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_3de3d65c81ae4cb890edd8ca2a775335",
            "placeholder": "​",
            "style": "IPY_MODEL_8ad927c14cb545949b9a0469f56a2247",
            "value": " 53/53 [00:00&lt;00:00, 1302.83 examples/s]"
          }
        },
        "9a2c3f47a31945d4ae4a15b1e6ff3dd9": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "2387bec179144eeca0eb18dd13951ef0": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "f52950002e984c21abe60ea75cbc0a81": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "7a8ac4fe8f7e4e8980c7b59b831ba0a2": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "15821bf8ec5042f38012e65a6a219725": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ProgressStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ProgressStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "bar_color": null,
            "description_width": ""
          }
        },
        "3de3d65c81ae4cb890edd8ca2a775335": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "8ad927c14cb545949b9a0469f56a2247": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        }
      }
    }
  },
  "nbformat": 4,
  "nbformat_minor": 0
}